Declare Function GetTempFileName Lib "Kernel" (ByVal cDriveLetter As Integer, ByVal lpPrefixString As String, ByVal wUnique As Integer, ByVal lpTempFileName As String) As Integer
' Grid Layout Type
Type TrueGridLayout
WhichLen As Integer 'length of which
Which As String 'which grid, TablePeople, etc.
TypeLen As Integer 'length of type
Type As String 'Factory or Current, could be anything
LastUpdatedLen As Integer 'length of date and time
LastUpdated As String 'last updated, date and time
ValueLen As Integer 'length of the layout
Value As Variant 'the layout, 2000 or more characters
End Type
Function GridGetLayout (TheFile As String, Which As String, What As String, TheGrid As Control) As Integer
' Logic: Read the file sequentially looking for the required saved layout.
' If found then set the grid with the stored layout information.
' If not found then exit without setting the grid.